import request from '@/utils/request'
export function insertOrUpdate(data) {
  return request({
    url: `/scm/material/type/insertOrUpdate`,
    method: 'put',
    data
  })
}
export function page(data) {
  return request({
    url: `/scm/material/type/page`,
    method: 'get',
    params: data
  })
}
export function del(id) {
  return request({
    url: `/scm/material/type/delete/${id}`,
    method: 'delete'

  })
}
export function download(id) {
  return request({
    url: `/scm/on/supplier/downloadFile/${id}`,
    method: 'get',
    responseType: 'arraybuffer'
  })
}
export function uploadFile(scmOrderDetailId, type) {
  return request({
    url: `/scm/material/type/uploadFile/${scmOrderDetailId}/${type}`,
    method: 'get',
    data: file
  })
}
export function canban(data) {
  return request({
    url: `/scm/material/canban`,
    method: 'get',
    params: data
  })
}
export function delday(id) {
  return request({
    url: `/scm/material/delete/${id}`,
    method: 'delete'
  })
}
export function xialakuang(data) {
  return request({
    url: `/scm/material/type/xialakuang`,
    method: 'get',
    params: data
  })
}

